package com.spring01.demo.entity;

import lombok.Data;
import lombok.Getter;
import lombok.Setter;
import org.springframework.context.annotation.Bean;
import org.springframework.stereotype.Component;

@Setter
@Getter
@Component
public class Book {

    private Integer id;
    private String name;
    private String author;
    private Double price;
    private String type;
    private String description;
    private String image;

    public Book() {
    }

    public Book(int id, String name, String author, double price, String type, String description, String image) {
        this.id = id;
        this.name = name;
        this.author = author;
        this.price = price;
        this.type = type;
        this.description = description;
        this.image = image;
    }

    @Override
    public String toString() {
        return "Book{" +
                "id=" + id +
                ", name='" + name + '\'' +
                ", author='" + author + '\'' +
                ", price=" + price +
                ", type='" + type + '\'' +
                ", description='" + description + '\'' +
                ", image='" + image + '\'' +
                '}';
    }

}
